<?php $view->extend('::base.html.php') ?>
<?php echo $view['actions']->render('AcmeTest:Index:listMenu', array('listid' => $listid, 'routeName' => $app->getRequest()->attributes->get('_route'))); ?>
<form action="<?php echo $view['router']->generate('account_groups_edit', array('id' => $id)) ?>" method="post" <?php echo $view['form']->enctype($form) ?>>
    <?php echo $view['form']->errors($form) ?>

	<?php echo $view['form']->row($form['title']) ?>
    <div class="muted">Select type <?php echo $selectType ?></div>
	<ul class="groups" data-prototype="<?php echo $view->escape($view['form']->widget($form['groups']->vars['prototype']['title'])) ?>">
		<?php 
			foreach ($form['groups'] as $group):				
		?>
		<li>
			Subscribers: <?php echo $view['actions']->render('RMDAccountBundle:Groups:countSubscribers', array('groupId' => $group->getVars()['value']->getId())); ?>
			<?php echo $view['form']->widget($group['title']); ?>
		</li>
		<?php endforeach; ?>
	</ul>
    <input type="submit" />
<?php echo $view['form']->widget($form['_token']); ?>
</form>